package by.wind.drebedengi.datalayer;

import java.util.HashMap;

public class GetAccessStatus extends AbstractAction {
	
	public static final String SOAP_ACTION = "getAccessStatus";
	public static final String METHOD_NAME = "getAccessStatus";
	
	private final String POSITIVE ="1";
	
	private boolean result;
	private String username;
	private String password;

	public GetAccessStatus(String username, String password) {
		this.username = username;
		this.password = password;
	}
	
	@Override
	public void loadData() throws Exception{
		HashMap<String, Object> propertyList = new HashMap<String, Object>();
		propertyList.put(Constants.API_ID_KEY, Constants.API_ID_VALUE);
		propertyList.put(Constants.LOGIN_KEY, username);
		propertyList.put(Constants.PASS_KEY, password);
			result = false;
			Object itsData =  loadData(METHOD_NAME, SOAP_ACTION, propertyList);
			result = true;
	}

	public boolean getResult() {
		return result;
	}
	
}
